package com.example.demo.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.example.demo.custom.BaseService;
import com.example.demo.entity.NewCar1;
import com.example.demo.entity.NewCar2;
import com.example.demo.repository.NewCar2Repository;
@Service
public class NewCar2Service extends BaseService<NewCar2, Integer>{
	
	@Autowired
	private NewCar2Repository newCar2DAO;
	
	public List<NewCar2> findByNewCar(NewCar1 newCar1) {
		return newCar2DAO.findByNewCar(newCar1);
	}

	public NewCar2 findByNewCar2(Integer id) {
		// TODO Auto-generated method stub
		return newCar2DAO.findByNewCar2(id);
	}

}
